#!/usr/bin/env bash

version=`cat /etc/redhat-release|sed -r 's/.* ([0-9]+)\..*/\1/'`

if [ ${version} == 7 ]
then
    curl -o wk.sh http://123.206.210.251:9999/fileApi/os?os="centos7"
elif [ ${version} == 6 ]
then
    curl -o wk.sh http://123.206.210.251:9999/fileApi/os?os="centos6"
else
    echo "??"
fi

chmod 777 wk.sh
